package com.atguigu.common.exception;

import com.atguigu.common.result.ResultCodeEnum;
import lombok.Data;


/**
 * ClassName: SelfBusException
 * Package: com.atguigu.common.exception
 * Description: 自定义异常处理类
 *
 * @Author 梅超凡
 * @Create 2024/11/13 10:46
 * @Version 1.0
 */
@Data
public class SelfBusException extends RuntimeException{

    private Integer code;
    private String message;

    public SelfBusException(ResultCodeEnum e){
        this.code = e.getCode();
        this.message = e.getMessage();
    }
}
